from django.shortcuts import render
from rest_framework import viewsets
from .models import Card
from .serializers import CardSerializer
from .permissions import IsAdminUserOrReadOnly
# Create your views here.
class CardViewSet(viewsets.ModelViewSet):
    queryset=Card.objects.all()
    serializer_class=CardSerializer
    permission_classes=[IsAdminUserOrReadOnly]